home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 January: Mac OS SDK / Dev.CD Jan 99 SDK1.toast / Development Kits / Interfaces&Libraries / Universal / Interfaces / ComponentIncludes / Components.k.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-08-17  |  2.1 KB  |  65 lines  |  [TEXT/MPS ]

  1. /*
  2.      File:        Components.k.h
  3.  
  4.      Contains:    Component Manager Interfaces.
  5.  
  6.      Version:    Technology:    System 7.5
  7.                  Release:    Universal Interfaces 3.2
  8.  
  9.      Copyright:    © 1991-1998 by Apple Computer, Inc., all rights reserved.
  10.  
  11.      Bugs?:        For bug reports, consult the following page on
  12.                  the World Wide Web:
  13.  
  14.                      http://developer.apple.com/bugreporter/
  15.  
  16. */
  17. #ifndef __COMPONENTS_K__
  18. #define __COMPONENTS_K__
  19.  
  20. #include <Components.h>
  21.  
  22. /*
  23.     Example usage:
  24.  
  25.         #define CALLCOMPONENT_BASENAME()    Fred
  26.         #define CALLCOMPONENT_GLOBALS()    FredGlobalsHandle
  27.         #include <Components.k.h>
  28.  
  29.     To specify that your component implementation does not use globals, do not #define CALLCOMPONENT_GLOBALS
  30. */
  31. #ifdef CALLCOMPONENT_BASENAME
  32.     #ifndef CALLCOMPONENT_GLOBALS
  33.         #define CALLCOMPONENT_GLOBALS() 
  34.         #define ADD_CALLCOMPONENT_COMMA 
  35.     #else
  36.         #define ADD_CALLCOMPONENT_COMMA ,
  37.     #endif
  38.     #define CALLCOMPONENT_GLUE(a,b) a##b
  39.     #define CALLCOMPONENT_STRCAT(a,b) CALLCOMPONENT_GLUE(a,b)
  40.     #define ADD_CALLCOMPONENT_BASENAME(name) CALLCOMPONENT_STRCAT(CALLCOMPONENT_BASENAME(),name)
  41.  
  42.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(Open) (CALLCOMPONENT_GLOBALS() ADD_CALLCOMPONENT_COMMA ComponentInstance  self);
  43.  
  44.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(Close) (CALLCOMPONENT_GLOBALS() ADD_CALLCOMPONENT_COMMA ComponentInstance  self);
  45.  
  46.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(CanDo) (CALLCOMPONENT_GLOBALS() ADD_CALLCOMPONENT_COMMA short  ftnNumber);
  47.  
  48.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(Version) (CALLCOMPONENT_GLOBALS());
  49.  
  50.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(Register) (CALLCOMPONENT_GLOBALS());
  51.  
  52.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(Target) (CALLCOMPONENT_GLOBALS() ADD_CALLCOMPONENT_COMMA ComponentInstance  target);
  53.  
  54.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(Unregister) (CALLCOMPONENT_GLOBALS());
  55.  
  56.     EXTERN_API( ComponentResult  ) ADD_CALLCOMPONENT_BASENAME(GetMPWorkFunction) (CALLCOMPONENT_GLOBALS() ADD_CALLCOMPONENT_COMMA ComponentMPWorkFunctionUPP * workFunction, void ** refCon);
  57.  
  58. #if !TARGET_OS_MAC
  59. #endif
  60. #endif    /* CALLCOMPONENT_BASENAME */
  61.  
  62.  
  63. #endif /* __COMPONENTS_K__ */
  64.  
  65.